/*
 *  AMPLogCenter.h
 *  AMPlugin
 *
 *  Created by Toan on 11/2/12.
 *  Copyright 2012 __MyCompanyName__. All rights reserved.
 *
 */

typedef enum {
	
	AMPPLUGIN_OK = 0,
	AMPPLUGIN_UNSUPPORTED_PROTOCOL,    /* 1 */
	AMPPLUGIN_FAILED_INIT,             /* 2 */
	AMPPLUGIN_URL_MALFORMAT,           /* 3 */
	AMPPLUGINL_MALFORMAT_USER,			/* 4 - NOT USED */
	AMPPLUGIN_COULDNT_RESOLVE_PROXY,   /* 5 */
	AMPPLUGIN_COULDNT_RESOLVE_HOST,    /* 6 */
	AMPPLUGIN_COULDNT_CONNECT,         /* 7 */
	AMPPLUGIN_FTP_WEIRD_SERVER_REPLY,  /* 8 */
	AMPPLUGIN_FTP_ACCESS_DENIED,       /* 9 a service was denied by the FTP server
	 due to lack of access - when login fails
	 this is not returned. */
	AMPPLUGIN_FTP_USER_PASSWORD_INCORRECT, /* 10 - NOT USED */
	AMPPLUGIN_FTP_WEIRD_PASS_REPLY,    /* 11 */
	AMPPLUGIN_FTP_WEIRD_USER_REPLY,    /* 12 */
	AMPPLUGIN_FTP_WEIRD_PASV_REPLY,    /* 13 */
	AMPPLUGIN_FTP_WEIRD_227_FORMAT,    /* 14 */
	AMPPLUGIN_FTP_CANT_GET_HOST,       /* 15 */
	AMPPLUGIN_FTP_CANT_RECONNECT,      /* 16 */
	AMPPLUGIN_FTP_COULDNT_SET_BINARY,  /* 17 */
	AMPPLUGIN_PARTIAL_FILE,            /* 18 */
	AMPPLUGIN_FTP_COULDNT_RETR_FILE,   /* 19 */
	AMPPLUGIN_FTP_WRITE_ERROR,         /* 20 */
	AMPPLUGIN_FTP_QUOTE_ERROR,         /* 21 */
	AMPPLUGIN_HTTP_RETURNED_ERROR,     /* 22 */
	AMPPLUGIN_WRITE_ERROR,             /* 23 */
	AMPPLUGIN_MALFORMAT_USER,          /* 24 - NOT USED */
	AMPPLUGIN_UPLOAD_FAILED,           /* 25 - failed upload "command" */
	AMPPLUGIN_READ_ERROR,              /* 26 - could open/read from file */
	AMPPLUGIN_OUT_OF_MEMORY,           /* 27 */
	/* Note: AMPPLUGIN_OUT_OF_MEMORY may sometimes indicate a conversion error
	 instead of a memory allocation error if CURL_DOES_CONVERSIONS
	 is defined
	 */
	AMPPLUGIN_OPERATION_TIMEOUTED,     /* 28 - the timeout time was reached */
	AMPPLUGIN_FTP_COULDNT_SET_ASCII,   /* 29 - TYPE A failed */
	AMPPLUGIN_FTP_PORT_FAILED,         /* 30 - FTP PORT operation failed */
	AMPPLUGIN_FTP_COULDNT_USE_REST,    /* 31 - the REST command failed */
	AMPPLUGIN_FTP_COULDNT_GET_SIZE,    /* 32 - the SIZE command failed */
	AMPPLUGIN_HTTP_RANGE_ERROR,        /* 33 - RANGE "command" didn't work */
	AMPPLUGIN_HTTP_POST_ERROR,         /* 34 */
	AMPPLUGIN_SSL_CONNECT_ERROR,       /* 35 - wrong when connecting with SSL */
	AMPPLUGIN_BAD_DOWNLOAD_RESUME,     /* 36 - couldn't resume download */
	AMPPLUGIN_FILE_COULDNT_READ_FILE,  /* 37 */
	AMPPLUGIN_LDAP_CANNOT_BIND,        /* 38 */
	AMPPLUGIN_LDAP_SEARCH_FAILED,      /* 39 */
	AMPPLUGIN_LIBRARY_NOT_FOUND,       /* 40 */
	AMPPLUGIN_FUNCTION_NOT_FOUND,      /* 41 */
	AMPPLUGIN_ABORTED_BY_CALLBACK,     /* 42 */
	AMPPLUGIN_BAD_FUNCTION_ARGUMENT,   /* 43 */
	AMPPLUGIN_BAD_CALLING_ORDER,       /* 44 - NOT USED */
	AMPPLUGIN_INTERFACE_FAILED,        /* 45 - CURLOPT_INTERFACE failed */
	AMPPLUGIN_BAD_PASSWORD_ENTERED,    /* 46 - NOT USED */
	AMPPLUGIN_TOO_MANY_REDIRECTS ,     /* 47 - catch endless re-direct loops */
	AMPPLUGIN_UNKNOWN_TELNET_OPTION,   /* 48 - User specified an unknown option */
	AMPPLUGIN_TELNET_OPTION_SYNTAX ,   /* 49 - Malformed telnet option */
	AMPPLUGIN_OBSOLETE,                /* 50 - NOT USED */
	AMPPLUGIN_SSL_PEER_CERTIFICATE,    /* 51 - peer's certificate wasn't ok */
	AMPPLUGIN_GOT_NOTHING,             /* 52 - when this is a specific error */
	AMPPLUGIN_SSL_ENGINE_NOTFOUND,     /* 53 - SSL crypto engine not found */
	AMPPLUGIN_SSL_ENGINE_SETFAILED,    /* 54 - can not set SSL crypto engine as
	 default */
	AMPPLUGIN_SEND_ERROR,              /* 55 - failed sending network data */
	AMPPLUGIN_RECV_ERROR,              /* 56 - failure in receiving network data */
	AMPPLUGIN_SHARE_IN_USE,            /* 57 - share is in use */
	AMPPLUGIN_SSL_CERTPROBLEM,         /* 58 - problem with the local certificate */
	AMPPLUGIN_SSL_CIPHER,              /* 59 - couldn't use specified cipher */
	AMPPLUGIN_SSL_CACERT,              /* 60 - problem with the CA cert (path?) */
	AMPPLUGIN_BAD_CONTENT_ENCODING,    /* 61 - Unrecognized transfer encoding */
	AMPPLUGIN_LDAP_INVALID_URL,        /* 62 - Invalid LDAP URL */
	AMPPLUGIN_FILESIZE_EXCEEDED,       /* 63 - Maximum file size exceeded */
	AMPPLUGIN_FTP_SSL_FAILED,          /* 64 - Requested FTP SSL level failed */
	AMPPLUGIN_SEND_FAIL_REWIND,        /* 65 - Sending the data requires a rewind
	 that failed */
	AMPPLUGIN_SSL_ENGINE_INITFAILED,   /* 66 - failed to initialise ENGINE */
	AMPPLUGIN_LOGIN_DENIED,            /* 67 - user, password or similar was not
	 accepted and we failed to login */
	AMPPLUGIN_TFTP_NOTFOUND,           /* 68 - file not found on server */
	AMPPLUGIN_TFTP_PERM,               /* 69 - permission problem on server */
	AMPPLUGIN_TFTP_DISKFULL,           /* 70 - out of disk space on server */
	AMPPLUGIN_TFTP_ILLEGAL,            /* 71 - Illegal TFTP operation */
	AMPPLUGIN_TFTP_UNKNOWNID,          /* 72 - Unknown transfer ID */
	AMPPLUGIN_TFTP_EXISTS,             /* 73 - File already exists */
	AMPPLUGIN_TFTP_NOSUCHUSER,         /* 74 - No such user */
	AMPPLUGIN_CONV_FAILED,             /* 75 - conversion failed */
	AMPPLUGIN_CONV_REQD,               /* 76 - caller must register conversion
	 callbacks using curl_easy_setopt options */
	AMPPLUGIN_SSL_CACERT_BADFILE,      /* 77 - could not load CACERT file, missing
	 or wrong format */
	AMPPLUGIN_REMOTE_FILE_NOT_FOUND,   /* 78 - remote file not found */
	AMPPLUGIN_SSH,                     /* 79 - error from the SSH layer, somewhat
	 generic so the error message will be of
	 interest when this has happened */
	
	AMPPLUGIN_SSL_SHUTDOWN_FAILED,     /* 80 - Failed to shut down the SSL
	 connection */
	
	AMPPLUGIN_COULDNT_PARSE_JSON,		/* 81 - Failed to parse json */
	AMPPLUGIN_COULDNT_EXPORT_JPG,		/* 82 - Failed to export jpeg image */
	AMPPLUGIN_COULDNT_EXPORT_IDML,		/* 83 - Failed to export idml file */
	AMPPLUGIN_COULDNT_IMPORT_IDML,		/* 84 - Failed to import idml file*/
	AMPPLUGIN_COULDNT_ASSIGN_NEW_IMAGE,	/* 85 - Failed to assign new image */
	AMPPLUGIN_COULDNT_AUTHENTICATION,	/* 86 - Failed to login */
	AMPPLUGIN_COULDNT_PROXY_LOGIN,		/* 87 - Failed to login */
	AMPPLUGIN_COULDNT_PROXY_AUTHENTICATION,		/* 88 - Failed to login */
	AMPPLUGIN_COULDNT_PROXY_CONNECTION,			/* 89 - Failed to login */
	AMPPLUGIN_COULDNT_CONNECTION_ERROR,			/* 90 - CONNECTION ERROR */
	AMPPLUGIN_DOWNLOADING_FAILED,				/* 91 - CONNECTION ERROR */
	AMPPLUGIN_UNLOCK_PAGES_FAILED,				/* 92 - CONNECTION ERROR */
	AMPPLUGIN_UNLOCK_STORY_FAILED,				/* 93 - CONNECTION ERROR */
	AMPPLUGIN_UPDATE_SESSION_FAILED,			/* 94 - CONNECTION ERROR */
	AMPPLUGIN_RENEW_SESSION_FAILED,				/* 95 - CONNECTION ERROR */
	AMPPLUGIN_GET_PACKAGE_URL_FAILED,			/* 96 - CONNECTION ERROR */
	AMPPLUGIN_GET_IMAGE_PREVIEW_DEFAULT_FAILED,	/* 97 - CONNECTION ERROR */
	AMPPLUGIN_CHECKOUT_FAILED,					/* 98 - CONNECTION ERROR */
	AMPPLUGIN_SHOW_ISSUE_LIST_FAILED,			/* 99 - CONNECTION ERROR */
	
	AMPPLUGIN_LAST /* never use! */
	
}AMPIDcode;

class AMPLogCenter {
public:
	static void DataLogCenter(int IDPCode);
};